//
//  ProductListViewCell.m
//  Tiger
//
//  Created by Ken on 11-10-18.
//  Copyright 2011 __MyCompanyName__. All rights reserved.
//

#import "ProductDetailViewCell.h"

@implementation ProductDetailViewCell
@synthesize productNameLabel;
- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
		
		productNameLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, 320, 20)];
		productNameLabel.textAlignment = UITextAlignmentCenter;
		productNameLabel.baselineAdjustment = UIBaselineAdjustmentAlignCenters;
		productNameLabel.lineBreakMode = UILineBreakModeWordWrap;
		productNameLabel.numberOfLines = 1;
		productNameLabel.font = [UIFont boldSystemFontOfSize:13];
		productNameLabel.textColor = [UIColor whiteColor];
		productNameLabel.backgroundColor = [UIColor clearColor];
		[self.contentView addSubview:productNameLabel];
		
		productNameEnLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, 15, 320, 25)];
		productNameEnLabel.textAlignment = UITextAlignmentCenter;
		productNameEnLabel.baselineAdjustment = UIBaselineAdjustmentAlignCenters;
		productNameEnLabel.lineBreakMode = UILineBreakModeWordWrap;
		productNameEnLabel.numberOfLines = 1;
		productNameEnLabel.font = [UIFont systemFontOfSize:13];
		productNameEnLabel.textColor = [UIColor grayColor];
		productNameEnLabel.backgroundColor = [UIColor clearColor];
		[self.contentView addSubview:productNameEnLabel];
    }
    return self;
}


#pragma mark Properties Methods

- (NSString *)productName { return productNameLabel.text; }
- (void)setProductName:(NSString *)d { productNameLabel.text = d; }


- (NSString *)productNameEn { return productNameEnLabel.text; }
- (void)setProductNameEn:(NSString *)d { productNameEnLabel.text = d; }


- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    
    [super setSelected:selected animated:animated];
    
    // Configure the view for the selected state.
}

- (void)dealloc {
	[productNameLabel release];
	[productNameEnLabel release];

    [super dealloc];
}


@end
